/**
 * Created by xnr on 2020-04-03.
 */
import request from "../utils/fetch";

//不分页,字典列表
export function list (data) {
  return request({
    url: "/dict/list",
    method: "get",
    requestBody: "null",
    loading: true,
    params: data,
  });
}
//修改字典
export function update (data) {
  return request({
    url: "/dict/update",
    method: "post",
    requestBody: "body",
    loading: true,
    data: data,
  });
}
//新增字典
export function add (data) {
  return request({
    url: "/dict/add",
    method: "post",
    requestBody: "body",
    loading: true,
    data: data,
  });
}

//删除字典
export function del (data) {
  return request({
    url: "/dict/delete",
    method: "post",
    requestBody: "query",
    loading: true,
    data: data,
  });
}
export function getDictListByparentCode (data) {
  return request({
    url: "/dict/getDictListByparentCode",
    method: "post",
    requestBody: "query",
    loading: true,
    data: data,
  });
}
export function getDictListBypid (data) {
  return request({
    url: "/dict/getDictListBypid",
    method: "post",
    requestBody: "query",
    loading: true,
    data: data,
  });
}
